<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>用户登录</title>
<script type="text/javascript">
	function checkForm() {
		if (form1.username.value == "") {
			alert("用户名不能为空");
			return false;
		}
		if (form1.password.value.length <=0) {
			alert("密码长度不能空");
			return false;
		}
		return true;
	}
</script>
</head>
<body>
	<form name="form1" action="login.jsp" method="POST" onSubmit="return checkForm();">
		姓名：<input type="text" name="username" style="width: 180px;" /><br />
		密码：<input type="password" name="password" style="width: 180px;" /><br />
		<input type="submit" value="登录" /> 
		<input type="reset" value="重置" /><br />
	</form>
</body>
</html>
